<#assign module="errand"/>

<@override name="header">
</@override>
<@override name="body">

	<div class="row">
		<div class="col-md-12">
			<div class="panel panel-default">
				<div class="panel-heading">
					新增收费内容
			    </div>
			    <div class="panel-body">
    				<form id="submit_form" action="${ctx}/errand/newfee" class="form-horizontal" method="post">
		               
		                <div class="form-group">
		                    <label class="col-sm-3 control-label"><em>*</em>名称：</label>
		                    <div class="col-sm-3">
		                    	<input class="form-control" id="name" name="name" type="text" required/>
		                    </div>
		                </div>
		                
		                <div class="form-group">
		                    <label class="col-sm-3 control-label"><em>*</em>acKey：</label>
		                    <div class="col-sm-3">
		                    	<input class="form-control" id="acKey" name="acKey" type="text" required/>
		                    </div>
		                </div>
		                
		                <div class="form-group" style="margin-left:10px;">
			                <label class="col-sm-3 control-label"></label>
			                <input id="submit_button" type="submit" class="btn btn-primary" value="保存">
			                <input type="button" class="btn btn-default" onclick="javasccript:history.go(-1);" value="返回">
			            </div>
			            
					</form>
        		</div>
			</div>
		</div>
	</div>

</@override>
<@override name="footer">
<script type="text/javascript">
	$(document).ready(function(){
		$("#submit_form").submit(function(){
			
			$("#submit_button").attr("disabled",true);
			
			$.post('${ctx}/errand/newfee',$("#submit_form").serialize(),function(result){
				if(result.success){
					window.location="${ctx}/errand/feelist";
				}
				else{
					$.scojs_message(result.message, $.scojs_message.TYPE_ERROR);
				}
			});
			
			return false;
		});
	
	});
</script>
</@override>
<@extends name="../layout.ftl"/>